home *** CD-ROM | disk | FTP | other *** search
/ Tech Arsenal 1 / Tech Arsenal (Arsenal Computer).ISO / tek-19 / gcpvu.zip / GERBER.DOC < prev    next >
Text File  |  1991-02-21  |  17KB  |  595 lines

  1.  
  2.  
  3.  
  4.  
  5.  
  6.  
  7.                                                    PHOTOPLOTTING PRINCIPLES
  8.  
  9.  
  10.  
  11.  
  12.            What's a Photoplotter?
  13.  
  14.  
  15.           A photoplotter is just what the name implies: an plotter that
  16.           writes using light.  A plotter has to be told:
  17.  
  18.             Which tool to use.
  19.             When to use the tool, and when not to.
  20.             Where to go next.
  21.             Whether to go there in a straight line or along an arc.
  22.  
  23.           For a photoplotter, "tool" means specially shaped apertures
  24.           through which light passes to create a given shape on film.  An
  25.           aperture can be used without movement to make a shape (a "flash")
  26.           or with movement to make a line or an arc.
  27.  
  28.           There are two major types of photoplotters, "Vector" and "Raster"
  29.           (or "laser").  Each handles apertures differently.
  30.  
  31.           Vector Photoplotters
  32.  
  33.           Aperture Wheels
  34.  
  35.           Traditionally, the photoplotter counterpart to a pen plotter's
  36.           pen rack has been the aperture wheel.  The aperture wheel is a
  37.           disk with 24 or 70 apertures arrayed radially along its
  38.           circumference.
  39.  
  40.           When the photoplotter selects an aperture, the aperture wheel is
  41.           rotated to place the desired aperture between the light source
  42.           and the film.  Apertures are themselves pieces of film and can be
  43.           made to any shape required, although in practice this is a time-
  44.           consuming process and there is a physical limitation on size.
  45.  
  46.           Flash and Draw Apertures
  47.  
  48.           To achieve constant exposure on a vector photoplotter, apertures
  49.           used for flashing pads are filtered differently than those used
  50.           for drawing traces.  Therefore, Flash and Draw apertures cannot
  51.           be used interchangeably without risk of localized over-exposure
  52.           and under-exposure.
  53.  
  54.           Aperture Wheel Setup for Vector Plotters
  55.  
  56.           The setup of an aperture wheel is an exacting and time consuming
  57.           process since each aperture in the wheel must be hand-mounted and
  58.           aligned.  In order to avoid repeated setup costs, designers have
  59.           the photoplotting vendor keep a wheel on file and are forced to
  60.           always use that same set of apertures.  This has obvious
  61.  
  62.  
  63.  
  64.  
  65.  
  66.  
  67.  
  68.  
  69.  
  70.  
  71.  
  72.  
  73.           drawbacks, both in terms of design flexibility and the ease of
  74.           migration to other vendors.
  75.  
  76.           Raster (Laser) Plotters
  77.  
  78.           Aperture Lists
  79.  
  80.           Increasingly, vector photoplotters are being replaced by the
  81.           laser photoplotter, which emulates the older style machine in a
  82.           raster (bit-map) fashion.  While use of the term "aperture" to
  83.           describe a pad or trace shape persists, the term "aperture wheel"
  84.           is now being replaced by "aperture list", which implies the
  85.           greater flexibility now available to the designer.
  86.  
  87.           There are three principle advantages with aperture lists on
  88.           raster plotters:
  89.  
  90.             Aperture shapes can be easily generated in software, thus
  91.             eliminating the need to design a physical wheel.
  92.             More apertures can be defined on a list.
  93.             Allowable apertures sizes are typically (but not always)
  94.             greater than those imposed by the physical dimensions of an
  95.             aperture wheel.
  96.  
  97.           Flash and Draw Apertures
  98.  
  99.           No distinction need be made between Flash and Draw aperture types
  100.           since the light source intensity is constant.
  101.  
  102.           Speed Advantage of Laser Plotters
  103.  
  104.           Laser plotters operate much quicker than vector machines.  A
  105.           complex plot that required hours on a vector machine can usually
  106.           be performed in ten minutes or less on a laser photoplotter.
  107.           This decreases turnaround time and in many markets has driven
  108.           photoplotting costs down.
  109.  
  110.           Talking to Photoplotters
  111.  
  112.           The de facto standard for photoplotter data is the Gerber format,
  113.           more properly known as RS-274D.  The term Gerber refers to the
  114.           Gerber Scientific Instrument company, a pioneer and leader in
  115.           photoplotter manufacturing.
  116.  
  117.           RS-274D is a variation on traditional Numerical Control (NC)
  118.           machine tool languages.  It differs from traditional NC formats
  119.           (i.e. drill data), as far as its use of tool selection codes but
  120.           is otherwise compatible.
  121.  
  122.           RS-274D data is organized in "blocks".  A block consists of a
  123.           combination of codes:
  124.  
  125.  
  126.  
  127.  
  128.  
  129.  
  130.  
  131.  
  132.  
  133.  
  134.  
  135.  
  136.  
  137.  
  138.  
  139.             Tool selection
  140.             Setup
  141.             Movement
  142.             And, an End Of Block (EOB) character, which only follows a
  143.             combination of the above codes.
  144.  
  145.           An EOB character is usually an asterisk ('*') or dollar ('$'),
  146.           optionally followed by a carriage return and line feed.
  147.  
  148.           An RS-274D code consists of a letter D,G,M,X,Y,I or J followed by
  149.           a numerical value.  These codes designate the following:
  150.  
  151.             * - End of Block (end of command)
  152.  
  153.             D - Select aperture, or set aperture use mode
  154.  
  155.             X - Move to X value
  156.  
  157.             Y - Move to Y value
  158.  
  159.             G - Various setup codes
  160.  
  161.             M - Various control codes
  162.  
  163.             I - Relative X location for arc center
  164.  
  165.             J - Relative Y location for arc center
  166.  
  167.           D Codes
  168.  
  169.           D codes have multiple purposes.  The first is to control the
  170.           state of the light being on or off. Valid codes for light state
  171.           are D01, D02, and D03.
  172.  
  173.             D01 - Light on for next move.
  174.  
  175.             D02 - Light off for next move.
  176.  
  177.             D03 - Flash (Light On, Light Off) after move (effect is limited
  178.             to block in which appears, ie non-modal).  You can also think
  179.             of a D03 as D02, D01, D02 series of commands linked together.
  180.  
  181.           D codes with values of 10 or greater represent the aperture's
  182.           position on the list or wheel.  It is very important to
  183.           understand that there is no universal "D10" or "D30".  Unlike the
  184.           D01 , D02, and D03 counterparts which have a fixed meaning (draw,
  185.           move, flash), D10 and higher values have aperture shapes and
  186.           dimensions assigned to them by each individual user.  Hence, one
  187.           job's D10 could be a 10 mil Round, when another job's D10 could
  188.           be a 45 mil Square.
  189.  
  190.           There are two distinct ways to number an aperture list.  The
  191.           traditional 24 aperture system started with D10 - D19, jumping
  192.           suddenly to D70 - D71, then back to D20 - D29, ending with D72 -
  193.  
  194.  
  195.  
  196.  
  197.  
  198.  
  199.  
  200.  
  201.  
  202.  
  203.  
  204.  
  205.           D73.  This is still a common format for output for CAD packages,
  206.           and is still mandatory for old 24 aperture Gerber vector
  207.           photoplotters.
  208.  
  209.           It is now common to start with D10, then increase numerically in
  210.           steps of 1 (D10, D11, etc.) continuing up to D70 and beyond,
  211.           rarely beyond 1000 individual apertures.
  212.  
  213.           X & Y Codes
  214.  
  215.           The X & Y values in the Gerber file determine where the aperture
  216.           shape and dimension will be positioned and drawn.  X & Y values
  217.           are used as coordinate pairs to determine where the light will be
  218.           exposed, using the D codes shapes (i.e. D10) and light exposure
  219.           status (i.e. D01, D02, D03) for drawing lines and arcs, as well
  220.           as moving between drawing entities.
  221.  
  222.           Here are a few examples of using X & Y codes with D codes.
  223.  
  224.             D10*  { Select aperture D10}
  225.  
  226.             X1000Y1000D02* { The D02 tells us that the light will be off,
  227.             and we move to coordinate position X1000 and Y1000}
  228.  
  229.             X2000Y3000D01* { The D01 tells us that we will draw (light on)
  230.             to coordinate position X2000 and Y3000}
  231.  
  232.             X5500Y100D03* { The D03 tells us to move to coordinate position
  233.             X5500 and Y100 with the light off, then flash (turn the light
  234.             on and off)}
  235.  
  236.           G Codes
  237.  
  238.           G codes are used to configure the photoplotter.  Commonly
  239.           implemented codes include:
  240.  
  241.  
  242.  
  243.  
  244.  
  245.  
  246.  
  247.  
  248.  
  249.  
  250.  
  251.  
  252.  
  253.  
  254.  
  255.  
  256.  
  257.  
  258.  
  259.  
  260.  
  261.  
  262.  
  263.  
  264.  
  265.  
  266.  
  267.  
  268.  
  269.  
  270.  
  271.             G01 - Future X,Y commands are straightline moves
  272.  
  273.             G02 - Future X,Y commands are clockwise arcs
  274.  
  275.             G03 - Future X,Y commands are counterclockwise arcs
  276.  
  277.             G04 - Ignore the rest of this block (used for Comments)
  278.  
  279.             G54 - Prepare to change apertures
  280.  
  281.             G74 - Future arcs are quadrant arcs
  282.  
  283.             G75 - Future arcs are Full 360 arcs
  284.  
  285.             G90 - Absolute data
  286.  
  287.             G91 - Incremental data
  288.  
  289.  
  290.  
  291.           Typically for laser photoplotters, G54 codes are rarely
  292.           necessary.  Older vector plotter controllers may require this
  293.           preparatory G codes for changing apertures (i.e. G54D10*).
  294.  
  295.           A common situation where G codes are mandatory for all machines
  296.           is when the data is switching from vectors to arcs and vice
  297.           versa.  When switching from drawing vectors (G01) to drawing arc
  298.           (G02, G03), the controller must be informed of the change of
  299.           mode.
  300.  
  301.           Another important case for G codes is when determining if the arc
  302.           is a quadrant (G74) or Full 360 (G75).  Quadrant arcs never cross
  303.           quadrant boundaries, because the center coordinate offsets (I,J
  304.           Codes) are always unsigned (even if they are negative!).
  305.           Therefore, it requires at least four G74 arcs to draw one
  306.           complete circle.
  307.  
  308.           Center coordinate offsets for 360 arcs (G75) can be positive or
  309.           negative, allowing for a single command to draw a complete
  310.           circle.
  311.  
  312.           In either case, the center coordinates are given relative to the
  313.           start point of the arc.  The most dramatic difference between
  314.           Quadrant and Full 360 arcs is that a Quadrant arc with identical
  315.           start and end points has a sweep of 0 degrees, whereas a similar
  316.           Full 360 arc is a full circle.
  317.  
  318.           The G90 code tells the machine controller that all data following
  319.           is absolute data.  Hence, if following X & Y data follows, the
  320.           controller will move to the absolute value given by the X & Y
  321.           value.
  322.  
  323.  
  324.  
  325.  
  326.  
  327.  
  328.  
  329.  
  330.  
  331.  
  332.  
  333.  
  334.  
  335.  
  336.  
  337.           G91 tells the machine controller that all data following is
  338.           incremental data.  The machine will move the data by the amount
  339.           of the X & Y value, rather than to the absolute coordinate point.
  340.  
  341.           Example:
  342.  
  343.             X1000Y1000D02*
  344.  
  345.             X3000Y3000D01*
  346.  
  347.  
  348.  
  349.           In absolute mode (G90), the machine will first move to coordinate
  350.           point X1000 and Y1000 with the light off, then draw a line to
  351.           coordinate point X3000 and Y3000 with the light on.
  352.  
  353.           In incremental mode (G91)  the machine will first move to
  354.           coordinate point X1000 and Y1000 with the light off, then draw a
  355.           line to coordinate point X4000 and Y4000 with the light on.  This
  356.           was done by adding X1000 + X3000 = X4000 and Y1000 + Y3000 =
  357.           Y4000.
  358.  
  359.           Here are some more examples of G code usage in conjunction with
  360.           X, Y, and D code values:
  361.  
  362.             G54D10*      { Prepare to change aperture position (G54), then
  363.             select aperture D10}
  364.  
  365.             G01X1000Y1000D02*      { Prepare to draw a vector (G01) then
  366.             turn off the light (D02) and move to coordinate position X1000
  367.             and Y1000}
  368.  
  369.             G90*    { This block (command) and all future commands will be
  370.             absolute data}
  371.  
  372.             X2000Y3000D01*    Turn the light on (D01) and move to absolute
  373.             coordinate position X2000 and Y3000}
  374.  
  375.             G91*              { The G91 command tells the controller that
  376.             this command and all future commands that the data is
  377.             incremental}
  378.  
  379.             X5500Y100D03*     { Turn the light off and move incrementally
  380.             by a value of X5500 and Y100, then flash (D03) (light on and
  381.             off)}
  382.  
  383.           M Codes
  384.  
  385.           M codes are used for machine control.  Here are the most commonly
  386.           used:
  387.  
  388.  
  389.  
  390.  
  391.  
  392.  
  393.  
  394.  
  395.  
  396.  
  397.  
  398.  
  399.  
  400.  
  401.  
  402.  
  403.             M00 - Full machine stop.  Commonly ignored by many plotters.
  404.  
  405.             M01 - Temporary machine stop.  Commonly ignored by many
  406.             plotters.
  407.  
  408.             M02 - End of Plot.
  409.  
  410.           I & J Codes
  411.  
  412.           When you encounter an I & J code in a Gerber block, you have
  413.           found an arc command.  Arc commands come in two flavors, Full 360
  414.           or Quadrant.  The Gerber arc command is very complicated, and
  415.           this section will only briefly describe usage of the Gerber arc.
  416.  
  417.           Full 360 arcs allow the plotter to draw a full circle (360
  418.           degrees of arc) in one single command..
  419.  
  420.           Quadrant arcs only allow for an arc to be drawn through a maximum
  421.           of 90 degrees of arc, never crossing a quadrant boundary.  Due to
  422.           this restriction, I and J arc center offset codes can get away
  423.           with never having a negative value, even if the offsets are
  424.           negative!
  425.  
  426.           When in a Full 360 arc (G75), only one command is required to
  427.           draw a circle.  In Quadrant mode, the same circle would require
  428.           at leaset 4 Quadrant arcs (G74), because a circle goes through
  429.           all four quadrants.
  430.  
  431.           Quadrant arcs will always have positively signed I and J values,
  432.           even if the center offset is actually negative.  Full 360 arc
  433.           center offsets can be signed positively or negatively.  A
  434.           negative I or J is a sure indicator of Full 360 arcs.
  435.  
  436.           Modality
  437.  
  438.           It is often the case with Gerber data that when moving from one
  439.           XY coordinate point to another XY coordinate point, the X or Y
  440.           value will not change.  Likewise, it is likely that if the
  441.           plotter is drawing a line with multiple segments, the segments
  442.           will be connected and the light stays on from segment to segment.
  443.  
  444.           In both of these cases, there are redundant commands, making the
  445.           plot data file larger than necessary.
  446.  
  447.           RS-274D allows you to omit this redundant data.  This example
  448.           shows a box being drawn with four corners.
  449.  
  450.  
  451.  
  452.  
  453.  
  454.  
  455.  
  456.  
  457.  
  458.  
  459.  
  460.  
  461.  
  462.  
  463.  
  464.  
  465.  
  466.  
  467.  
  468.  
  469.             Non Modal Data         Modal Data
  470.  
  471.             X0000Y0000D02*         X1000Y1000D02*
  472.  
  473.             X0000Y1000D01*         Y1000D01*
  474.  
  475.             X1000Y1000D01*         X1000*
  476.  
  477.             X1000Y0000D01*         Y0000*
  478.  
  479.             X0000Y0000D01*         X0000*
  480.  
  481.           From this example, a large amount of data has not been written,
  482.           thus reducing the final data file size.
  483.  
  484.           Establishing the Decimal Point
  485.  
  486.           A numerical value in RS-274D data has an integer and a decimal
  487.           part, but the decimal point ('.') is not a valid RS-274D
  488.           character.  Thus, decimal values are written as a string of
  489.           integers.  The implicit position of the decimal point is
  490.           determined by three parameters:
  491.  
  492.             Number of integer digits (whole digits)
  493.             Number of decimal digits (precision)
  494.             Zero suppression.
  495.  
  496.           For example: In a system with integer digits=n and decimal
  497.           digits=m (an "n,m" system), a numerical value is written using
  498.           (n+m) digits.
  499.  
  500.           For example, in a "2,3" format the value 12.345 is written
  501.           "12345".  In a "2,4" format, the same value is written "123450".
  502.  
  503.           Zero suppression comes in three flavors - leading, trailing and
  504.           none.  The idea of zero suppression is to reduce data file sizes
  505.           by eliminating unneeded 0 characters.  The simplest and most
  506.           common form of zero suppression is leading zero suppression.
  507.  
  508.           In a "2,4" format, with no zero suppression, the value 0.0100
  509.           would be 00 + 01000, written as "000100", but with leading zero
  510.           suppression the same value is written as "100".
  511.  
  512.           With trailing zero suppression the same value 0.0100 would be
  513.           written as "0001".
  514.  
  515.           How To Describe Data Formats
  516.  
  517.           Gerber data and other XY languages use a standard method for
  518.           describing the data format.  Two examples include:
  519.  
  520.  
  521.  
  522.  
  523.  
  524.  
  525.  
  526.  
  527.  
  528.  
  529.  
  530.  
  531.  
  532.  
  533.  
  534.  
  535.             "2,3 leading inch" or "3,3 trailing metric".  The first number
  536.             specifies the whole digits used.  The second parameter states
  537.             the precision.  "Leading" and "trailing" pertain to the zero
  538.             suppression.  And the last part of the description indicates
  539.             the units.  Refer to the above sections if these concepts seem
  540.             unclear.
  541.  
  542.  
  543.  
  544.  
  545.  
  546.  
  547.  
  548.  
  549.  
  550.  
  551.  
  552.  
  553.  
  554.  
  555.  
  556.  
  557.  
  558.  
  559.  
  560.  
  561.  
  562.  
  563.  
  564.  
  565.  
  566.  
  567.  
  568.  
  569.  
  570.  
  571.  
  572.  
  573.  
  574.  
  575.  
  576.  
  577.  
  578.  
  579.  
  580.  
  581.  
  582.  
  583.  
  584.  
  585.  
  586.  
  587.  
  588.  
  589.  
  590.  
  591.  
  592.  
  593.  
  594.  
  595.